import { getAction, deleteAction, putAction, postAction, httpAction } from '@/api/manage'

const connectDevice = (params) => getAction("/tiger/tigDeviceCommu/connect", params);
const getDeviceinfo = (params) => getAction("/tiger/tigDeviceCommu/getDeviceinfo", params);
const getDeviceinfoList = (params) => getAction("/tiger/tigDevice/list", params);
const getIsExistDevicesByOrgCode = (params) => getAction("/tiger/tigDevice/queryIsExistDevicesByOrgCode", params);

const disConnectDevice = (params) => getAction("/tiger/tigDeviceCommu/disconnect", params);
const setDevice = (params) => getAction("/tiger/tigDeviceCommu/setDevice", params);

const getDeviceinfoListShort = (params) => getAction("/tiger/tigDevice/shortList", params);
const updateDepartDevices = (params) => postAction("/departs/tigerDepartDevice/addBatch", params);
const getDepartDevices = (params) => getAction("/departs/tigerDepartDevice/list", params);
const runRecovery = (params) => getAction("/util/tigerDataBackup/recover", params);

const getDepartDevicesTree = (params) => getAction("/departs/tigerDepartDevice/tigerDepartDeviceTree", params);
const getDepartDevicesTreeDetail = (params) => getAction("/departs/tigerDepartDevice/tigerDepartDeviceTreeDetail", params);

const getDeviceStatistics = (params) => getAction("/tigstatics/tigStatistics/queryStatistics",params);
const getDeviceStatisticsByDays = (params) => getAction("/tigstatics/tigStatistics/queryStatisticsdays",params);


export {
    connectDevice,
    getDeviceinfo,
    disConnectDevice,
    setDevice,
    getDeviceinfoList,
    getIsExistDevicesByOrgCode,
    getDeviceinfoListShort,
    updateDepartDevices,
    getDepartDevices,
    runRecovery,
    getDepartDevicesTree,
    getDepartDevicesTreeDetail,
    getDeviceStatistics,
    getDeviceStatisticsByDays
}